// Agent consumer_Alison in project swatJacamo

/* Initial beliefs and rules */

/* Initial goals */

!consume.

/* Plans */


+!consume: true
	<- 	?bufferReady;
		!consumeItems.
		
+!consumeItems: true
	<- 	get(Item);
		!consumeItem(Item);
		!!consumeItems.
		
+!consumeItem(Item) : true
	<- 	.my_name(Me);
		println(Me,": ",Item).
		
+?bufferReady : true
	<- 	lookupArtifact("myBuffer",_).

-?bufferReady : true
	<-	.wait(50);
		?bufferReady.
